package com.kinyx;

import java.io.IOException;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.core.env.ConfigurableEnvironment;

@SpringBootApplication // 自动配置
public class KMain {

	public static ConfigurableEnvironment env = null;

	public static void main(final String[] args) throws IOException {
		// 创建应用
		final SpringApplication app = new SpringApplication(KMain.class);

		// 添加初始化对象
		app.addInitializers(applicationContext -> env = applicationContext.getEnvironment());

		// 启动应用
		app.run(args);
	}

}
